{% extends '../../../source/frontend/layouts/skins/v2/layout.volt' %}

{% block title %}
    <div id="serp-header" class="promo-header"></div>
    <div class="search-bar">
        <div class="container">
            <div class="row">
                <div class="search-summary">
                    <div class="search-title">
                        Kết quả tìm kiếm với
                        <span class="search-title-query">{{ key }}</span>
                    </div>
                </div>
            </div>
        </div>
    </div>
{% endblock %}

{% block content %}
    {% if(videos|length) %}
        <div class="row">
            <div>
                <div class="subtray">
                    {% for video in videos %}
                        <div class="item">
                            <div class="thumbnail">
                                <a href="{{url(video.getLinkTo())}}">
                                    {{ image(helper.getPathImageFromImageLink(video.getMainImages() , '220_124')) }}
                                    <div class="description">
                                        <div class="title">
                                            {{video.videoDescription.getName()}}
                                        </div>
                                    </div>
                                </a>
                            </div>
                        </div>
                    {% endfor %}
                </div>
            </div>
        </div>

        <div class="row">
            {% if videos.haveToPaginate() %}
                <div class="text-center">
                    {{ videos.getLayout() }}
                </div>
            {% endif %}
        </div>
    {% endif %}
{% endblock %}